﻿' _______                 _      _        _____               _       
'|__   __|               | |    | |      |  __ \             | |      
'   | | _   _  _ __ ___  | |__  | |  ___ | |  | |  ___   ___ | | __   
'   | || | | || '_ ` _ \ | '_ \ | | / _ \| |  | | / _ \ / __|| |/ /   
'   | || |_| || | | | | || |_) || ||  __/| |__| ||  __/| (__ |   <  _ 
'   |_| \__,_||_| |_| |_||_.__/ |_| \___||_____/  \___| \___||_|\_\(_)
Imports TumblePower
Public Class Tumblarity
    'You don't need to modify the form
    Private score As Integer 'Calculated score
    Dim acct As New tumblr.Account
    Private TumblrData As tumblr

    'I kept these apart, they may be used later
    Dim MyPostsLikeSCORE As Integer
    Dim MyPostsReblogSCORE As Integer
    Dim MyFollowersSCORE As Integer
    Dim MyReblogsSCORE As Integer

    Dim MyPostsLike As Integer = 1 + MyPostsLikeSCORE
    Dim MyPostsReblog As Integer = 3 + MyPostsReblogSCORE
    Dim MyFollowers As Integer = 3 + MyFollowersSCORE
    Dim MyReblogs As Integer = 3 + MyReblogsSCORE

    Private Sub CalculateScore() 'Calculate score
        'Set MyPostsLikeSCORE, MyPostsReblogSCORE, MyFollowersSCORE and MyReblogsSCORE
        score = MyPostsLike + MyPostsReblog + MyFollowers + MyReblogs 'Add them together to make "score"
        My.Settings.TumblarityScore = CStr(score) 'Save the score in Settings
    End Sub

    Private Sub InfoLinkLabel_LinkClicked(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles HelpLinkLabel.LinkClicked
        MessageBox.Show("How do we calculate your Tumblarity?" & vbLf & vbLf & "• 1 point for every Like your post gets" & vbLf & "• 3 points for every Reblog your post gets" & vbLf & "• 3 points for every new follower you get" & vbLf & "• 3 points for every Reblog of other people’s post" & vbLf & vbLf & "You start with 10 points, just for downloading TumbleDeck!", "How do we calculate your Tumblarity?")
    End Sub

    Private Sub Tumblarity_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        CalculateScore()
        TumblarityLabel.Text = My.Settings.TumblarityScore 'Display the score
    End Sub
End Class